{extend name="public/base"} 
{block name="title"}{$title}{/block}
{block name="jsValue"}
<script type="text/javascript">
    var $backUrl = '{$backUrl}';
    var $free_type = parseInt('{$cur.free_type}');
</script>
{/block} 
{block name="body"}
<div class="layui-fluid">
    <div class="layui-row">
        <div class="layui-card">
            <div class="layui-card-header">
                {$title}
            </div>
            <div class="layui-card-body">
                <div class="layui-form">
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">书籍名称1：</label>
                            <div class="layui-input-block">
                                <input type="text" name="name" value="{$cur.name}" class="layui-input" />
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">主角：</label>
                            <div class="layui-input-block">
                                <input type="text" name="lead" value="{:isset($cur.lead)?$cur.lead:''}" class="layui-input" />
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg3">
                            <label class="layui-form-label">作者：</label>
                            <div class="layui-input-block">
                                <input type="text" name="author" value="{$cur.author}" class="layui-input" />
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">状态：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($status,$cur['status'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">封面：</label>
                        <div class="layui-input-block">
                            <div class="image-div">
                                <div class="image-box size-120x170" title="点击上传小说封面" onclick="javascript:cropImage('上传小说封面图片', '210x290', this);">
                                    {empty name="cur.cover"}
                                    <img src="/static/common/images/240x340.png" class="showimg"/>
                                    {else /}
                                    <img src="{$cur.cover}" class="showimg"/>
                                    {/empty}
                                    <input type="hidden" class="hideval" name="cover" value="{$cur.cover}"/>
                                </div>
                                <div class="image-remark">点击可更换书籍封面图片</div>
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <label class="layui-form-label">详情图片：</label>
                        <div class="layui-input-block">
                            <div class="image-div">
                                <div class="image-box size-375x210" title="点击上传小说详情图片" onclick="javascript:cropImage('上传小说详情图片', '750x420', this);">
                                    {empty name="cur.detail_img"}
                                    <img src="/static/common/images/375x210.png" class="showimg"/>
                                    {else /}
                                    <img src="{$cur.detail_img}" class="showimg" />
                                    {/empty}
                                    <input type="hidden" class="hideval" name="detail_img" value="{$cur.detail_img}"/>
                                </div>

                                <div class="image-remark">点击可更换详情图片</div>
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg5">
                            <label class="layui-form-label">简介：</label>
                            <div class="layui-input-block">
                                <textarea class="layui-textarea" name="summary">{$cur.summary}</textarea>
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">发布区域：</label>
                            <div class="layui-input-block">
                                {:createCheckBoxHtml($area,'area',$cur['area'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg3">
                            <label class="layui-form-label">排序权值：</label>
                            <div class="layui-input-block">
                                <input type="text" name="sort_num" value="{$cur.sort_num}" class="layui-input" />
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">排序权值仅在各发布区域生效，由大到小排列</div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">类型：</label>
                            <div class="layui-input-block">
                                {:createCheckBoxHtml($category,'category',$cur['category'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">书籍属性：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($free_type,$cur['free_type'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item free-input-line">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">免费章节：</label>
                            <div class="layui-input-block">
                                <input type="text" name="free_chapter" value="{$cur.free_chapter}" class="layui-input" />
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">设定值前的章节阅读免费</div>
                    </div>
                    <div class="layui-form-item free-input-line">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">付费书币：</label>
                            <div class="layui-input-block">
                                <input type="text" name="money" value="{$cur.money}" class="layui-input" />
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">免费章节后每章节收取多少书币</div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">书籍进度：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($over_type,$cur['over_type'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">是否新书：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($new_type,$cur['new_type'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">篇幅：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($long_type,$cur['long_type'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">所属频道：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($gender_type,$cur['gender_type'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">是否热门推荐：</label>
                            <div class="layui-input-block">
                                {:createRadioHtml($is_hot,$cur['is_hot'])}
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">初始化人气值：</label>
                            <div class="layui-input-block">
                                <input type="text" name="hot_num" value="{$cur.hot_num}" class="layui-input" />
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">书籍详情页展示,此后每当用户进入该页面，人气值+1</div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg4">
                            <label class="layui-form-label">分享标题：</label>
                            <div class="layui-input-block">
                                <input type="text" name="share_title" value="{$cur.share_title}" class="layui-input" />
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">分享数据时，标题为该项设定的值</div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-lg5">
                            <label class="layui-form-label">分享简介：</label>
                            <div class="layui-input-block">
                                <textarea class="layui-textarea" name="share_desc">{$cur.share_desc}</textarea>
                            </div>
                        </div>
                        <div class="layui-form-mid layui-word-aux">分享书籍时，简介为该项设定的值</div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-input-block">
                            <input type="hidden" value="{$cur.id}" name="id" />
                            <a class="layui-btn" lay-submit lay-filter="dosubmit">保存</a>
                            <a type="reset" class="layui-btn layui-btn-primary" href="{$backUrl}">返回</a>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
{/block}
{block name="footJs"}
<script type="text/javascript" src="__JS__/admin.public.dobook.js"></script>
{/block}